<?php
/*
 * Author: Quan Van Sinh
 * Email: sinhvnb@vietnambiz.com
 * Update: NghiaTruong
 * Email: nghiatruong@vietnambiz.com
 * Date: 16-3-2011
 */
checkLoginHeader();
checkPermission();
$searchlog = new searchlog();
?>
<?php include_once $config ['admin_theme_path'].$config ['admin_theme'].'/header.php'; ?>

<div id="wrapper">
            <div id="content" style="width: 98%;">

                <div id="rightnow">
                    <h3 class="reallynow">
                        <span>Keyword</span>
                        <br />
                    </h3>
                    <div class="youhave">
                        <table width="100%">
                            <tbody>
                                <tr>
                                    <td width="40px">&nbsp;</td>
                                    <td><b>Keyword</b></td>
                                    <td width="60" align="center"><b>Count</b></td>
                                </tr>
                                <?php
                                    $rsAllKeyword = $searchlog->getAllKeyword();
                                    $i=0;
                                    while($rs=$db->fetch_array($rsAllKeyword['rs'])){
                                        $i++;
                                ?>
                                <tr>
                                    <td class="a-center"><? echo $i;?></td>
                                    <td><? echo $rs['keyword'];?></td>
                                    <td width="60" align="center"><? echo $rs['count'];?></td>
                                </tr>
                                <?php }?>
                                </tbody>
                        </table>
                    </div>
                  </div>
                <div class="linepagination">
                <div class="pagination">
                    <ul>
                            <?php
                            $totalRows =  $rsAllKeyword['totalRows'];
                            $totalPages = ceil($totalRows/$config ['total_article_on_admin']);
                            echo pagingAdmin($config ['page'],$totalPages,'','');
                            ?>
                    </ul>
                </div>

            </div>
            </div>

      </div>
<?php include_once $config ['admin_theme_path'].$config ['admin_theme'].'/footer.php'; ?>